config := meta.(*Config)

// current import_formats cannot import fields with forward slashes in their value
if err := parseImportId([]string{
		"(?P<envgroup_id>.+)/attachments/(?P<name>.+)",
		"(?P<envgroup_id>.+)/(?P<name>.+)",
	}, d, config); err != nil {
		return nil, err
	}

// Replace import id for the resource id
id, err := replaceVars(d, config, "{{envgroup_id}}/attachments/{{name}}")
if err != nil {
	return nil, fmt.Errorf("Error constructing id: %s", err)
}
d.SetId(id)

return []*schema.ResourceData{d}, nil
